import http from "../utils/http";
const api = {
  // 获取总收入
  getTotalIncome () {
    return http({
      url: '/home/getAllMoney',
      method: 'get'
    })
  },
  // 获取周同比
  getYoyWeekly () {
    return http({
      url: '/home/revenueOnWeek',
      method: 'get'
    })
  },
  // 获取日环比
  getDayOnMonth () {
    return http({
      url: '/home/revenueOnDay',
      method: 'get'
    })
  },
  // 获取日均收入
  getDayIncome () {
    return http({
      url: '/home/AverageDailyIncome',
      method: 'get'
    })
  },
  // 获取车流量
  getTotalFlow () {
    return http({
      url: '/home/getAllCar',
      method: 'get'
    })
  },
  // 获取日访问量
  getDayFlow () {
    return http({
      url: '/home/DailyVisits',
      method: 'get'
    })
  },
  // 获取ETC支付笔数
  getEtcPayNum () {
    return http({
      url: '/home/getETCPaycounQuantity',
      method: 'get'
    })
  },
  // 获取ETC使用率
  getUtilizationRate () {
    return http({
      url: '/home/ETCUsageRate',
      method: 'get'
    })
  },
  // 获取车位占用率
  getOccupancy () {
    return http({
      url: '/home/ParkingSpaceOccupancyRate',
      method: 'get'
    })
  },
  // 获取车位周同比
  getParkingLotRise () {
    return http({
      url: '/home/ParkingSpaceOccupancyRateOnWeek',
      method: 'get'
    })
  },
  // 获取车位日环比
  getParkingLotFall () {
    return http({
      url: '/home/ParkingSpaceOccupancyRateOnDay',
      method: 'get'
    })
  },
  // ------------------------图表部分------------------------------------------------
  // 获取车流量图表数据
  getParkingCharts () {
    return http({
      url: '/home/carHistogram',
      method: "get"
    })
  },
  // 获取ETC图表数据
  getEtcCharts () {
    return http({
      url: '/home/ETCHistogram',
      method: "get"
    })
  },
  // 获取日收入趋势表数据
  getDailyIncome () {
    return http({
      url: '/home/getHistogram',
      method: "get"
    })
  },
  // 获取支付方式图表数据
  getPaymentMethod () {
    return http({
      url: '/home/getFanChart',
      method: "get"
    })
  },
  // 获取访问量图表数据
  getVisits () {
    return http({
      url: '/home/traffic',
      method: "get"
    })
  }
}

export default api